﻿@{
    string realName = "";
    if(Roles.IsUserInRole("ExpertJudge"))
    {
        using(PessModel.PESSEntities db = new PessModel.PESSEntities())
        {
            var expert = db.ExpertJudges.Find(User.Identity.Name);
            if(expert!=null&&expert.RealName!=null)
            {
                realName = expert.RealName;
            }
        }
    }
}
@if(Request.IsAuthenticated) {
    <text><span id="userInfo">欢迎 <strong>@User.Identity.Name @realName</strong>!   [ </span>@Html.ActionLink("退出", "LogOff", "Account")<span> ]&nbsp;</span>@Html.ActionLink(" 个人设置 ","Settings","Account") </text>
}
else {
    @:[ @Html.ActionLink(" 登录 ", "LogOn", "Account") ]
}
